package com.sc.nft.entity.dto;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;

@Data
public class ModificationAddRessDTO {
    @ApiModelProperty(value = "地址id")
    @NotNull(message = "地址id不能为空")
    private Long id;

    @ApiModelProperty(value = "收件人姓名")
    @NotBlank(message = "收件人姓名不能为空")
    private String recipientName;

    @ApiModelProperty(value = "联系电话")
    @NotBlank(message = "手机号不能为空")
    @Pattern(regexp = "1[3-9][0-9]\\d{8}", message = "手机号格式不正确")
    private String contactNumber;

    @ApiModelProperty(value = "省/州/自治区")
    @NotBlank(message = "省/州/自治区不能为空")
    private String state;

    @ApiModelProperty(value = "城市")
    @NotBlank(message = "市不能为空")
    private String city;

    @ApiModelProperty(value = "县/乡/区")
    @NotBlank(message = "县/乡/区不能为空")
    private String area;

    @ApiModelProperty(value = "详情地址")
    @NotBlank(message = "详细地址不能为空")
    private String detailedAddress;


    @ApiModelProperty(value = "是否为默认地址  false:不是 true:是")
    private Boolean defaultAddress;
}
